﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Configuration;

namespace WebMainSite
{
    public class CommonHelp
    {
        /// <summary>
        /// 把Copyright的相关信息配置在web.config里面，这个函数获取出来
        /// </summary>
        /// <returns>Copyright</returns>
        public static string GetCopyright()
        {
            try
            {
                string copyright = ConfigurationManager.AppSettings["Copyright"];
                string coptightTitle = ConfigurationManager.AppSettings["CopyrightTitle"];
                string copyrightLink = ConfigurationManager.AppSettings["CopyrightLink"];
                string companyName = ConfigurationManager.AppSettings["CompanyName"];
                string divHtmlInner = "<p>" + copyright + "  <b><a href=\"" + copyrightLink + "\" title=\"" + coptightTitle + "\">" + companyName + "</a></b></p>";
                return divHtmlInner;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
    }
}